#!/usr/bin/python
# -*- coding: UTF-8 -*-

import argparse
import os 
import json
from sys import version
from Gamecontroller import *

# WORKDIR = 'config/workdir.json'
CONFIG = ""
SCRIPT = ""
PROJECT = ""


# 配置列表读取操作
def packageorder(area,game,version):
    PROJECT = str(config["projectlocation"])
    CONFIG = PROJECT + '/' + str(config["configjson"])
    SCRIPT = PROJECT + '/' + str(config["packagebuilder"])
    print(CONFIG)
    print(SCRIPT)
    print("trying to package game...")
    print("python " + SCRIPT + " -c " + CONFIG + '/' + area +'/' + game + '.json' + " -v " + str(version))
    os.system("python " + SCRIPT + " -c " + CONFIG + '/' + area +'/' + game + '.json' + " -v " + str(version))

# 游戏反查地区进行补全
# if __name__ == "__main__":
#     packInOrder("tianjin")
